package avicit.bdp.dms.tdm.utils;

import avicit.bdp.core.enums.BaseEnum;

public enum ApplyServiceType implements BaseEnum {
  DATA_QUERY(1, "数据查询"),
  DATA_PUSH(2, "数据推送"),
  API(3, "API接口"),
  DOWNLOAD(4, "下载"),
  MODEL(5, "模型"),
  REPORT(6, "报表");

  ApplyServiceType(int code, String descp) {
    this.code = code;
    this.descp = descp;
  }

  private final int code;
  private final String descp;

  public static ApplyServiceType valueOf(int value) {
    for (ApplyServiceType o : values()) {
      if (o.getCode() == value) {
        return o;
      }
    }
    return null;
  }

  public int getCode() {
    return code;
  }

  public String getDescp() {
    return descp;
  }

}
